home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Nebula 2
/
Nebula Two.iso
/
SourceCode
/
Palettes
/
TabMatrixPalette1.5
/
TabMatrixPalette.m
< prev
next >
Wrap
Text File
|
1995-06-12
|
1KB
|
46 lines
#import "TabMatrixPalette.h"
#import "UITabActionCell.subproj/UITabActionCell.h"
@implementation TabMatrixPalette
- finishInstantiate
{
NXRect frameRect;
Matrix *newMatrix;
[matrix getFrame:&frameRect];
newMatrix =
[[Matrix allocFromZone:[self zone]]
initFrame:&frameRect
mode:NX_RADIOMODE
prototype:[[UITabActionCell allocFromZone:[self zone]] initTextCell:"Folder Tab"]
numRows:1
numCols:2];
[[matrix superview] replaceSubview:matrix with:newMatrix];
[matrix free];
matrix = newMatrix;
// set the background gray of tabMatrix to NX_DKGRAY
[matrix setBackgroundGray:NX_DKGRAY];
// set the autosizing and autoscrolling attributes of the matrix
[matrix setAutosizing:NX_WIDTHSIZABLE];
[matrix setAutoscroll:YES];
// size tabMatrix to its cells, resize matrix so that nice NX_DKGRAY border
// frames tabs, and display it
[matrix sizeToFit];
[matrix setAutosizeCells:YES];
[matrix sizeBy:0.0 :4.0];
[matrix display];
return self;
}
@end